﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using EnhancedWebControls;

namespace EwcControlTest
{
    public partial class Site1 : System.Web.UI.MasterPage
    {
        public bool ApplySkin
        {
            get
            {
                return this.chkSkinned.Checked;
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!Page.IsPostBack)
            {
                //this.NavigationBar.DataSource = GetMenuItems();
            }
        }
        public static List<NavBarMenuItem> GetMenuItems()
        {
            List<NavBarMenuItem> rval = new List<NavBarMenuItem>();
            rval.Add(new NavBarMenuItem { MenuID = 1, ParentID = 0, MenuText = "Home", MenuDescription = "Default Page", NavigateUrl = "~/Default.aspx", HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 2, ParentID = 0, MenuText = "Labeled Inputs", MenuDescription = "Test the Labeled Input Controls", NavigateUrl = null, HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 3, ParentID = 2, MenuText = "EnhancedTextBox", MenuDescription = "Test the Enhanced Text Box Control", NavigateUrl = "~/EnhancedTextBoxes.aspx", HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 4, ParentID = 2, MenuText = "EnhancedDropDown", MenuDescription = "Test the Enhanced Drop Down Control", NavigateUrl = "~/EnhancedDropDowns.aspx", HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 5, ParentID = 2, MenuText = "EnhancedCheckBox", MenuDescription = "Test the Enhanced Check Box Control", NavigateUrl = "~/EnhancedCheckBoxes.aspx", HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 6, ParentID = 2, MenuText = "EnhancedCalendar", MenuDescription = "Test the Enhanced Calendar Control", NavigateUrl = "~/EnhancedCalendars.aspx", HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 16, ParentID = 2, MenuText = "MultiSelectDropDown", MenuDescription = "Test the Multi Select Drop Down Control", NavigateUrl = "~/MultiSelectDropDowns.aspx", HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 7, ParentID = 0, MenuText = "Buttons", MenuDescription = "Test the Enhanced Buttons", NavigateUrl = null, HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 8, ParentID = 7, MenuText = "EnhancedButton", MenuDescription = "Test the Enhanced Button", NavigateUrl = "~/EnhancedButtons.aspx", HideInMenu = true, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 9, ParentID = 7, MenuText = "EnhancedLinkButton", MenuDescription = "Test the Enhanced Link Button", NavigateUrl = "~/EnhancedLinkButtons.aspx", HideInMenu = true, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 10, ParentID = 0, MenuText = "Panels & Popups", MenuDescription = "Test Panels and Popups", NavigateUrl = null, HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 11, ParentID = 10, MenuText = "MessageBox", MenuDescription = "Test the MessageBox Control", NavigateUrl = "~/MessageBoxes.aspx", HideInMenu = true, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 12, ParentID = 10, MenuText = "CustomMessagePanel", MenuDescription = "Test the CustomMessagePanel Control", NavigateUrl = "~/CustomMessagePanel.aspx", HideInMenu = true, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 13, ParentID = 10, MenuText = "PopUpPanel", MenuDescription = "Test the PopUpPanel Control", NavigateUrl = "~/PopUpPanels.aspx", HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 14, ParentID = 10, MenuText = "ModalProgressPanels", MenuDescription = "Test the ModalProgressPanel Control", NavigateUrl = "~/ModalProgressPanels.aspx", HideInMenu = false, OpenInNewWindow = false });
            rval.Add(new NavBarMenuItem { MenuID = 15, ParentID = 0, MenuText = "NavBars", MenuDescription = "Test the NavBar Control", NavigateUrl = "~/NavBars.aspx", HideInMenu = false, OpenInNewWindow = false });
            return rval;
        }
        public static List<UsState> GetUsStatesList()
        {
            List<UsState> rval = new List<UsState>();
            rval.Add(new UsState() { Abbreviation = "AL", Name = "Alabama" });
            rval.Add(new UsState() { Abbreviation = "AK", Name = "Alaska" });
            rval.Add(new UsState() { Abbreviation = "AZ", Name = "Arizona" });
            rval.Add(new UsState() { Abbreviation = "AR", Name = "Arkansas" });
            rval.Add(new UsState() { Abbreviation = "CA", Name = "California" });
            rval.Add(new UsState() { Abbreviation = "CO", Name = "Colorado" });
            rval.Add(new UsState() { Abbreviation = "CT", Name = "Connecticut" });
            rval.Add(new UsState() { Abbreviation = "DC", Name = "District of Columbia" });
            rval.Add(new UsState() { Abbreviation = "DE", Name = "Delaware" });
            rval.Add(new UsState() { Abbreviation = "FL", Name = "Florida" });
            rval.Add(new UsState() { Abbreviation = "GA", Name = "Georgia" });
            rval.Add(new UsState() { Abbreviation = "HI", Name = "Hawaii" });
            rval.Add(new UsState() { Abbreviation = "ID", Name = "Idaho" });
            rval.Add(new UsState() { Abbreviation = "IL", Name = "Illinois" });
            rval.Add(new UsState() { Abbreviation = "IN", Name = "Indiana" });
            rval.Add(new UsState() { Abbreviation = "IA", Name = "Iowa" });
            rval.Add(new UsState() { Abbreviation = "KS", Name = "Kansas" });
            rval.Add(new UsState() { Abbreviation = "KY", Name = "Kentucky" });
            rval.Add(new UsState() { Abbreviation = "LA", Name = "Louisiana" });
            rval.Add(new UsState() { Abbreviation = "ME", Name = "Maine" });
            rval.Add(new UsState() { Abbreviation = "MD", Name = "Maryland" });
            rval.Add(new UsState() { Abbreviation = "MA", Name = "Massachusetts" });
            rval.Add(new UsState() { Abbreviation = "MI", Name = "Michigan" });
            rval.Add(new UsState() { Abbreviation = "MN", Name = "Minnesota" });
            rval.Add(new UsState() { Abbreviation = "MS", Name = "Mississippi" });
            rval.Add(new UsState() { Abbreviation = "MO", Name = "Missouri" });
            rval.Add(new UsState() { Abbreviation = "MT", Name = "Montana" });
            rval.Add(new UsState() { Abbreviation = "NE", Name = "Nebraska" });
            rval.Add(new UsState() { Abbreviation = "NV", Name = "Nevada" });
            rval.Add(new UsState() { Abbreviation = "NH", Name = "New Hampshire" });
            rval.Add(new UsState() { Abbreviation = "NJ", Name = "New Jersey" });
            rval.Add(new UsState() { Abbreviation = "NM", Name = "New Mexico" });
            rval.Add(new UsState() { Abbreviation = "NY", Name = "New York" });
            rval.Add(new UsState() { Abbreviation = "NC", Name = "North Carolina" });
            rval.Add(new UsState() { Abbreviation = "ND", Name = "North Dakota" });
            rval.Add(new UsState() { Abbreviation = "OH", Name = "Ohio" });
            rval.Add(new UsState() { Abbreviation = "OK", Name = "Oklahoma" });
            rval.Add(new UsState() { Abbreviation = "OR", Name = "Oregon" });
            rval.Add(new UsState() { Abbreviation = "PA", Name = "Pennsylvania" });
            rval.Add(new UsState() { Abbreviation = "RI", Name = "Rhode Island" });
            rval.Add(new UsState() { Abbreviation = "SC", Name = "South Carolina" });
            rval.Add(new UsState() { Abbreviation = "SD", Name = "South Dakota" });
            rval.Add(new UsState() { Abbreviation = "TN", Name = "Tennessee" });
            rval.Add(new UsState() { Abbreviation = "TX", Name = "Texas" });
            rval.Add(new UsState() { Abbreviation = "UT", Name = "Utah" });
            rval.Add(new UsState() { Abbreviation = "VT", Name = "Vermont" });
            rval.Add(new UsState() { Abbreviation = "VA", Name = "Virginia" });
            rval.Add(new UsState() { Abbreviation = "WA", Name = "Washington" });
            rval.Add(new UsState() { Abbreviation = "WV", Name = "West Virginia" });
            rval.Add(new UsState() { Abbreviation = "WI", Name = "Wisconsin" });
            rval.Add(new UsState() { Abbreviation = "WY", Name = "Wyoming" });
            return rval;
        }
    }
    public class UsState
    {
        public string Abbreviation { get; set; }
        public string Name { get; set; }
    }
}
